/*
    Syntactic sugar for old functions.
*/

@use "sass:color";

@function red($color) {
    @return color.channel($color, "red", $space: rgb);
}

@function green($color) {
    @return color.channel($color, "green", $space: rgb);
}

@function blue($color) {
    @return color.channel($color, "blue", $space: rgb);
}

@function transparentize($color, $amount) {
    @return color.adjust($color, $alpha: (1 - $amount) * -1);
}

@function lighten($color, $amount) {
    @return color.adjust($color, $lightness: $amount);
}

@function darken($color, $amount) {
    @return color.adjust($color, $lightness: $amount * -1);
}
